﻿@using System.Collections
@model SIFIET.GestionContenidos.Datos.Modelo.ATRIBUTO

@{
    ViewBag.Title = "Visualizar Categoria";
}

<h2>Visualizar Categoria</h2>

<fieldset>
    <legend>Categoria</legend>

    <div class="display-label">
        <label>Nombre: </label>
    </div>
    <div class="display-field">
        <label>@ViewBag.categoria.NOMBRECATEGORIA</label>
    </div>
    <div class="display-label">
        <label>Descripcion:</label>
    </div>
    <div class="display-field">
        <label>@ViewBag.categoria.DESCRIPCIONCATEGORIA</label>
    </div>
    <div class="display-label">
        <label>
            Visible:
        </label>
    </div>
    <div class="display-field">
        @if (@ViewBag.categoria.VISIBLEPRINCIPALCATEGORIA == 1)
        {
            <div class="display-field">Si</div>
        }
        else
        {
            <div class="display-field">No</div>
        }
    </div>
    
</fieldset>
<div>
    @if (ViewBag.listaAtributos != null)
    {
        <table>
            <thead>
                <tr>
                    <td>Nombre</td>
                    <td>Tipo</td>
                    <td>Acciones</td>
                </tr>
            </thead>
            <tbody>
                @foreach (SIFIET.GestionContenidos.Datos.Modelo.ATRIBUTO atributo in ViewBag.listaAtributos)
                {
                    <tr>
                        <td>@atributo.NOMBREATRIBUTO</td>
                        <td>@atributo.TIPOATRIBUTO</td>
                        

                    </tr>
                }
            </tbody>
        </table>
    }
    else
    {
        @Html.Label("No Atributos Registrados")
    }


</div>


<div>
    @Html.ActionLink("Editar", "ModificarCategoria", new { idCategoria = ViewBag.categoria.IDENTIFICADORCATEGORIA })
    @Html.ActionLink("Volver", "Index") 
</div>

<script src="@Url.Content("~/Scripts/jquery-1.10.2.min.js")" type="text/javascript"></script>
<script src="~/Scripts/jquery.validate.min.js"></script>
<script src="~/Scripts/funciones.js"></script>
<script src="@Url.Content("~/Scripts/jquery.unobtrusive-ajax.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-1.5.1.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-ui-1.8.11.min.js")" type="text/javascript"></script>
<script src="~/Scripts/jquery.validate.unobtrusive.min.js"></script>
